

import UIKit

class XWLuckyCollectionViewCell: UICollectionViewCell {

    private var XWImageView:UIImageView!
    override func awakeFromNib() {
        super.awakeFromNib()
        XWImageView = UIImageView.init(image: UIImage.init(named: "news_games_flip_green"))
        XWImageView.contentMode = .scaleToFill
        XWImageView.frame = self.contentView.bounds
        self.contentView.addSubview(XWImageView)
    }
    var dic:Dictionary<String,Any>?{
        didSet{
            if dic!["isSelected"] as! Bool == true{
                XWImageView.image = UIImage.init(named: "news_games_flip_yellow")
            }else{
                XWImageView.image = UIImage.init(named: "news_games_flip_green")
            }
        }
    }
}
